def dayUP(df, rest_day_factor):
    dayup = 1
    for i in range(365):
        if i % 4 in [0, 1, 2]:
            dayup = dayup * (1 + df)  # 工作日每天增加1%
        else:
            dayup = dayup * (1 + rest_day_factor)  # 休息日不下降
    return dayup

dayfactor = 0.01
rest_day_factor = 0  # 休息日不下降

while dayUP(dayfactor, rest_day_factor) < 37.78:
    dayfactor += 0.001

print("工作3天休息1天，每天努力增加1%，休息日不下降的努力参数是：{:.3f}".format(dayfactor))